package com.example.houtai.mapper;

import com.example.houtai.entity.SysRoleDept;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.org.dto.RoleDto;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 角色与部门对应关系 Mapper 接口
 * </p>
 *
 * @author 龚梦
 * @since 2021-03-22
 */
public interface SysRoleDeptMapper extends BaseMapper<SysRoleDept> {

    @Delete("delete from sys_role_dept where role_id=#{roleId}")
    void deleteByRoleId(@Param("roleId") Long roleId);


    List<RoleDto> selRoleByDeptId(Integer deptId);
}
